﻿package chapter_07_Homework;

import java.util.Scanner;

/*
 * 		更新会员积分。
 */
public class Work_11 {
	public static void main(String[] args) {
		int[] points = new int[5];
		int[] newPoints = new int[5];
		System.out.println("请输入5位会员积分");
		Scanner sc = new Scanner(System.in);
		for (int i = 0; i < newPoints.length; i++) {
			System.out.print("请输入第"+(i+1)+"位会员积分：");
			points[i] = sc.nextInt();
		}
		for (int i = 0; i < newPoints.length; i++) {
			newPoints[i]= points[i];
			newPoints[i] += 500;
		}
		System.out.println("\n序号\t\t历史积分\t\t更新积分");
		for (int i = 0; i < newPoints.length; i++) {
			System.out.println((i+1)+"\t\t"+points[i]+"\t\t\t"+newPoints[i]);
		}
	}
}
